import 'dart:convert';

import 'package:largefriends/entity/json/json_parse_utils.dart';

class LfNotificationStatusEntity {
  LfNotificationStatusEntity({
    this.activity = 1,
    this.connection = 1,
    this.message = 1,
  });

  factory LfNotificationStatusEntity.fromJson(Map<String, dynamic> jsonRes) =>
      LfNotificationStatusEntity(
        activity: jsonRes.asInt('activity', 1),
        connection: jsonRes.asInt('connection', 1),
        message: jsonRes.asInt('message', 1),
      );

  int activity = 1;
  int connection = 1;
  int message = 1;

  @override
  String toString() {
    return jsonEncode(this);
  }

  Map<String, dynamic> toJson() => <String, dynamic>{
        'activity': activity,
        'connection': connection,
        'message': message,
      };
}
